﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Introduction.ascx.cs" Inherits="Admin_Components_MasterData_Introduction" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolkit" %>
<telerik:RadScriptManager ID="ScriptManager2" runat="server" EnableTheming="True"></telerik:RadScriptManager>

<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
     <div class="form-horizontal wrapper-center clearfix">
         <!--Block bên trái -->
                 <div class="form-group col-md-6">
                     <!--Dòng -->
                    <div class="form-group">
                        <label class="col-md-4 control-label">
                           Thuộc loại</label>
                        <div class="col-md-7">
                            <telerik:RadComboBox ID="cbType" runat="server" CssClass="col-imp-6" TabIndex="1" Width="70px" AllowCustomText="false"    AutoPostBack="true" OnSelectedIndexChanged="cbType_SelectedIndexChanged" >
                                <Items>
                                <telerik:RadComboBoxItem Text="Giới thiệu về công ty" Value="C" />
                                <telerik:RadComboBoxItem Text="Giới thiệu gạo" Value="R" />
                            </Items>
                            </telerik:RadComboBox>
                        <asp:RequiredFieldValidator  ID="RequiredFieldValidator2" runat="server" ControlToValidate="cbType" ValidationGroup="g1"
                           ErrorMessage="Required(*)" InitialValue=""></asp:RequiredFieldValidator>
                        </div>
                    </div>
                  <!--End Dòng -->
                 
                <!--Dòng -->
                <div class="form-group">
                    <label class="col-md-3 control-label"></label>
                    <div class="col-md-5"></div>
                </div>
                <!--End Dòng -->
                <!--Dòng -->
                <div class="form-group">
                    <label class="col-md-3 control-label"></label>
                    <div class="col-md-5"></div>
                </div>
                <!--End Dòng -->
                <!--Dòng -->
                <div class="form-group">
                    <label class="col-md-3 control-label"></label>
                    <div class="col-md-5"></div>
                </div>
                <!--End Dòng -->
                <!--Dòng -->
                <div class="form-group">
                    <label class="col-md-4 control-label">Nội dung chi tiết<span style="color:red;">(*)</span></label>
                    <div class="col-md-5">
                      <telerik:RadEditor runat="server" ID="RadEditorContent" SkinID="BasicSetOfTools"  EnableResize="true" Width="600px" Height="300px" >
                                 <Content></Content>
                            </telerik:RadEditor>
                            <asp:RequiredFieldValidator ID="ResumeValidator" runat="server" ErrorMessage="Required(*)" ValidationGroup="g1"
                    ControlToValidate="RadEditorContent" Display="Dynamic"/>
                     </div>
                </div>
                <!--End Dòng -->
                <!--Dòng -->
                <div class="form-group">
                    <label class="col-md-3 control-label"></label>
                    <div class="col-md-5"></div>
                </div>
                <!--End Dòng -->
                     <!--Dòng -->
                <div class="form-group">
                    <label class="col-md-3 control-label"></label>
                    <div class="col-md-5"></div>
                </div>
                <!--End Dòng -->
                     <!--Dòng -->
                <div class="form-group">
                    <label class="col-md-3 control-label"></label>
                    <div class="col-md-5"></div>
                </div>
                <!--End Dòng -->
                </div>
                 <!--End Block bên trái -->
                 <!--Block bên phải -->
                <div class="form-group col-md-6">
                    <!--Dòng -->
                     <div class="form-group">
                        <label class="col-md-3 control-label">Người cập nhật</label>
                        <div class="col-md-8">
                           <telerik:RadTextBox ID="txtLastUpdatedBy" CssClass="col-imp-4 inputForm" Width="40px" runat="server"   Enabled ="false"/>
                         </div>
                    </div>
                    <!--End Dòng -->
                     <!--Dòng -->
                     <div class="form-group">
                        <label class="col-md-3 control-label">Ngày cập nhật</label>
                        <div class="col-md-8">
                           <telerik:RadTextBox ID="txtLastUpdatedDateTime" CssClass="col-imp-4 inputForm" Width="40px" runat="server"   Enabled ="false"/>
                         </div>
                    </div>
                    <!--End Dòng -->
                </div>
                 <!--End Block bên phải -->
      </div>
    <!--Action-->
            <div class="set-btns text-center">           
                <asp:Button ID="btnSave" CssClass="btn btn-sm btn-primary" runat="server" Text="Lưu"  OnClick="btnSave_Click" ValidationGroup="g1" />
            </div>
            <!--End Action -->
</ContentTemplate>
<Triggers>
<asp:PostBackTrigger ControlID="btnSave" />
</Triggers>
</asp:UpdatePanel>
<div class="progressbar">
    <asp:UpdateProgress ID="up" runat="server" AssociatedUpdatePanelID="UpdatePanel1">
        <ProgressTemplate>
            <div class="bg">
                <div class="progress progress-striped active">
                    <div class="progress-bar" role="progressbar" aria-valuenow="45" aria-valuemin="0"
                        aria-valuemax="100" style="width: 100%">
                        <span class="sr-only">100% Complete</span>
                    </div>
                </div>
            </div>
        </ProgressTemplate>
    </asp:UpdateProgress>
</div>
<script>
    function FormatNumber(obj) {

        var x;

        if (eval(obj))

            x = eval(obj).value;

        else

            x = obj;

        var num = x.replace(/$|,/g, '');

        if (isNaN(num)) { num = ""; }

        sign = (num == (num = Math.abs(num)));

        num = Math.floor(num * 100 + 0.50000000001);

        num = Math.floor(num / 100).toString();

        for (var i = 0; i < Math.floor((num.length - (1 + i)) / 3) ; i++) {

            num = num.substring(0, num.length - (4 * i + 3)) + ',' + num.substring(num.length - (4 * i + 3));

        }

        eval(obj).value = num;

    }
</script>